/*
 * Copyright 2013-2019 Xia Jun(3979434@qq.com).
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
 ***************************************************************************************
 *                                                                                     *
 *                        Website : http://www.farsunset.com                           *
 *                                                                                     *
 ***************************************************************************************
 */
package com.workcell.workdata.im.entity;

import javax.persistence.*;
import java.util.Date;

/**
 * 朋友圈文章实体
 */
@Entity
@Table(name = "t_hoxin_moment")
public class Moment{
	

	/**
	 * 单个图片
	 */
	public static final byte FORMAT_IMAGE = 0;

	/**
	 * 网址连接
	 */
	public static final byte FORMAT_LINK = 1;

	/**
	 * 视频
	 */
	public static final byte FORMAT_VIDEO = 2;

	/**
	 * 文字
	 */
	public static final byte FORMAT_TEXT = 3;

	/**
	 * 多个图片
	 */
	public static final  byte FORMAT_MULTI_IMAGE = 4;


	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@Column(name = "id")
	private Long id;

	@Column(name = "uid", nullable = false)
	private Long uid;

	@Column(name = "text", length = 1000)
	private String text;

	@Column(name = "content", length = 2000)
	private String content;

	@Column(name = "type",nullable = false)
	private Byte type;
 
	@Column(name = "extra", length = 1000)
	private String extra;
	
	@Column(name = "create_time",nullable = false)
	private Date createTime;

	public String getText() {
		return text;
	}

	public void setText(String text) {
		this.text = text;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public String getExtra() {
		return extra;
	}

	public void setExtra(String extra) {
		this.extra = extra;
	}

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public Byte getType() {
		return type;
	}

	public void setType(Byte type) {
		this.type = type;
	}

	public Long getUid() {
		return uid;
	}

	public void setUid(Long uid) {
		this.uid = uid;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

}
